/**
 * Copyright (C) BFH www.bfh.ch 2011
 * Code written by: Patrick Dobler, Marc Folly
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
package ch.bfh.ti.kybernetik.gui.slick.components;

import javax.vecmath.Point2d;

import ch.bfh.ti.kybernetik.gui.slick.GuiSimulator;

/**
 * This Class defines a {@link SlickComponent} as selectable. Meaning it can be
 * selected on the {@link GuiSimulator}
 * 
 * @param <T>
 *            the underling Model instance
 */
public interface SelectableSlickComponent<T> extends SlickComponent<T> {
	/**
	 * Set the {@link SelectableSlickComponent} as selected
	 * 
	 * @param selected
	 */
	public void setSelected(boolean selected);

	/**
	 * 
	 * @return true if the component is selected
	 */
	public boolean isSelected();

	/**
	 * Checks if a given {@link Point2d} intersects with this
	 * {@link SelectableSlickComponent}
	 * 
	 * @param point
	 * @return true if the given point intersects with this
	 *         {@link SelectableSlickComponent}
	 */
	public boolean intersectWithPoint(Point2d point);

	/**
	 * sets the x-coorindates of this {@link SlickComponent}
	 * 
	 * @param x
	 */
	public void setX(double x);

	/**
	 * sets the y-coorindates of this {@link SlickComponent}
	 * 
	 * @param Y
	 */
	public void setY(double Y);

}
